package com.example.m1.service.impl;

import com.example.m1.mapper.M1Mapper;
import com.example.service1.common.pojo.M1;
import com.example.m1.service.M1Service;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class M1ServiceImpl implements M1Service {

    @Autowired
    private M1Mapper m1Mapper;

    @Override
    public M1 updateInfo(M1 m1) {
        int i = m1Mapper.updateInfo(m1);
        if(i!=0){
            return m1Mapper.selectById(m1.getId());
        }
        return null;
    }
}
